import java.util.Scanner;

public class test2 {

   /* public static void main(String[] args) {

        String str = new String("9");
        long[] flag = new long[10];
        long sum=0;
        for(int i=0;i<10;i++){
            str += "9";
            flag[i] = Long.parseLong(str);
            sum +=flag[i];
            System.out.println(flag[i]);
        }
        System.out.println(sum);
    }
*/


    public static void main(String[] args) {
        int count = 0;
        Scanner scanner = new Scanner(System.in);
        while(scanner.nextInt()>=0){

            count++;
        }

        System.out.println(count);
    }
}
